<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:p="http://primefaces.org/ui">
        
    <h:head>
         <h:outputStylesheet library="css" name="style.css" />     
 	</h:head> 
     <h:body> 
       <h:form>
         <p:accordionPanel value="#{menuBean.listMenuUsuario}" var="menu" activeIndex="#{menuBean.activeTabIndex}"   >  
            <p:ajax event="tabChange" listener="#{menuBean.onTabChange}" />
		    <p:tab title="#{menu.nome}" titleStyle="background: url('../resources/images/#{menu.icon}'); 
		                                           repeat none; background-repeat:no-repeat;
		                                           padding-left: 35px; background-position:10px; ">  
		        <p:dataList value="#{menu.listMenuItem}" var="menuItem">
                     <p:column>
				           <table>
				             <tr>
				               <td>
				                    <h:graphicImage library="images" value="/resources/images/imgMenuItem.png" />  			               
				               </td>
				               
				               <td>
				                  <p:commandLink id="idLinkMenu" value="#{menuItem.nome}"  action="#{menuBean.gotoMenuItem(menuItem)}"
				                                  styleClass="label-link-sem-underline" ajax="true">
	                                  <h:outputLabel value="#{menuItem.nome}"  />
	                              </p:commandLink>	
				               </td>
				             </tr>
				           </table>
				           <div class="div-espaco-1"/>
                     </p:column>
          		</p:dataList>	  
		    </p:tab>  
		</p:accordionPanel>  
	   </h:form> 	
     </h:body>
</html>